# -----------------------------------------------
# Author: yuz
# Copyright: 湖南零檬信息技术有限公司
# Email: wagyu2016@163.com
# Phone&Wechat: 18173179913
# Site: http://www.lemonban.com
# Forum: http://testingpai.com
# -----------------------------------------------
import requests

# 发送请求：1、url, 2, 请求方法

url = 'http://httpbin.org/post'
# 发送 get 请求
response = requests.get(url)
print(response.text)

try:
    my_dict = response.json()
except:
    my_dict = {"msg": response.text}

print(my_dict)
